﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework.Input;

namespace Dark_Dungeon
{
    static public class Controls
    {
        static public KeyboardState oldState, newState;

        //Movimiento
        static public Keys MOVE_UP = Keys.Up;
        static public Keys MOVE_DOWN = Keys.Down;
        static public Keys MOVE_LEFT = Keys.Left;
        static public Keys MOVE_RIGHT = Keys.Right;

        //Ataque
        static public Keys ATTACK = Keys.A;

        //Guardar/Cargar juego
        static public Keys SAVE_GAME = Keys.F5;
        static public Keys LOAD_GAME = Keys.F6;

        static public bool checkKey(Keys thekey)
        {
            KeyboardState newstate = Keyboard.GetState();
            return oldState.IsKeyUp(thekey) && newstate.IsKeyDown(thekey);
        }
    }
}
